<?php

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/


Route::get("/qnpolicy/policyuploadform","QnPolicyController@policyuploadform");
Route::middleware(['admin.auth','platform.auth'])->group(function () {


    Route::get("/", 'IndexController@index');

    /**
     * 票台
     */
    Route::get("/booking/lists",'BookingController@lists');
    Route::get("/booking/ajaxLists",'BookingController@ajaxLists');

    /**
     * OTA分配权限
     */
    Route::get("/adminplatform/add","AdminPlatformController@add");
    Route::post("/adminplatform/ajaxAdd","AdminPlatformController@ajaxAdd");
    Route::get("/adminplatform/lists","AdminPlatformController@lists");
    Route::get("/adminplatform/ajaxLists","AdminPlatformController@ajaxLists");
    Route::get("/adminplatform/update","AdminPlatformController@update");
    Route::put("/adminplatform/ajaxUpdate","AdminPlatformController@ajaxUpdate");
    Route::delete("/adminplatform/ajaxDelete","AdminPlatformController@ajaxDelete");

    /**
     * 政策
     */
    Route::get("/policy/add",'PolicyController@add');
    Route::post("/policy/ajaxAdd",'PolicyController@ajaxAdd');
    Route::get("/policy/lists",'PolicyController@lists');
    Route::get("/policy/ajaxLists",'PolicyController@ajaxLists');
    Route::get("/policy/add",'PolicyController@add');
    Route::get("/policy/update",'PolicyController@update');
    Route::put("/policy/ajaxUpdate",'PolicyController@ajaxUpdate');
    Route::delete("/policy/ajaxDelete",'PolicyController@ajaxDelete');
    Route::put('/policy/itemUpdate','PolicyController@itemUpdate');

    //上传的政策ID
    Route::get("/policyupload/add","PolicyUploadController@add");
    Route::post("/policyupload/ajaxAdd","PolicyUploadController@ajaxAdd");
    Route::get("/policyupload/lists","PolicyUploadController@lists");
    Route::get("/policyupload/ajaxLists","PolicyUploadController@ajaxLists");
    Route::get("/policyupload/update","PolicyUploadController@update");
    Route::put("/policyupload/ajaxUpdate","PolicyUploadController@ajaxUpdate");
    Route::put("/policyupload/itemUpdate","PolicyUploadController@itemUpdate");
    Route::delete("/policyupload/ajaxDelete","PolicyUploadController@ajaxDelete");

    //上传规则运价
    Route::get("/rulepolicy/add","RulePolicyController@add");
    Route::post("/rulepolicy/ajaxAdd","RulePolicyController@ajaxAdd");
    Route::get("/rulepolicy/lists","RulePolicyController@lists");
    Route::get("/rulepolicy/ajaxLists","RulePolicyController@ajaxLists");
    Route::get("/rulepolicy/update","RulePolicyController@update");
    Route::put("/rulepolicy/ajaxUpdate","RulePolicyController@ajaxUpdate");
    Route::put("/rulepolicy/itemUpdate","RulePolicyController@itemUpdate");
    Route::delete("/rulepolicy/ajaxDelete","RulePolicyController@ajaxDelete");

    //比价工具
    Route::get("/compare/ctrip","CompareController@ctrip");
    Route::get("/compare/tc","CompareController@tc");
    Route::get("/compare/qn","CompareController@qn");
    Route::get("/compare/ajaxCtrip","CompareController@ajaxCtrip");
    Route::get("/compare/ajaxTc","CompareController@ajaxTc");
    Route::get("/compare/ajaxQn","CompareController@ajaxQn");

    //去哪的政策ID
    Route::get("/qnpolicy/add","QnPolicyController@add");
    Route::get("/qnpolicy/single","QnPolicyController@single");
    Route::get("/qnpolicy/round","QnPolicyController@round");
    Route::post("/qnpolicy/ajaxAdd","QnPolicyController@ajaxAdd");
    Route::post("/qnpolicy/roundUpload","QnPolicyController@roundUpload");
    Route::post("/qnpolicy/roundBatchUpload","QnPolicyController@roundBatchUpload");
    Route::get("/qnpolicy/lists","QnPolicyController@lists");
    Route::get("/qnpolicy/ajaxLists","QnPolicyController@ajaxLists");
    Route::get("/qnpolicy/update","QnPolicyController@update");
    Route::get("/qnpolicy/singleUpdate","QnPolicyController@singleUpdate");
    Route::put("/qnpolicy/ajaxUpdate","QnPolicyController@ajaxUpdate");
    Route::put("/qnpolicy/itemUpdate","QnPolicyController@itemUpdate");
    Route::delete("/qnpolicy/ajaxDelete","QnPolicyController@ajaxDelete");

    //同程的政策ID
    Route::get("/tcpolicy/add","TcPolicyController@add");
    Route::post("/tcpolicy/ajaxAdd","TcPolicyController@ajaxAdd");
    Route::get("/tcpolicy/lists","TcPolicyController@lists");
    Route::get("/tcpolicy/ajaxLists","TcPolicyController@ajaxLists");
    Route::get("/tcpolicy/update","TcPolicyController@update");
    Route::put("/tcpolicy/ajaxUpdate","TcPolicyController@ajaxUpdate");
    Route::put("/tcpolicy/itemUpdate","TcPolicyController@itemUpdate");
    Route::delete("/tcpolicy/ajaxDelete","TcPolicyController@ajaxDelete");

    //普通政策
    Route::get("/policycommonupload/ajaxLists","PolicyCommonUploadController@ajaxLists");

    //同程普通政策
    Route::get("/tccommonpolicy/add","TcCommonPolicyController@add");
    Route::post("/tccommonpolicy/ajaxAdd","TcCommonPolicyController@ajaxAdd");
    Route::get("/tccommonpolicy/lists","TcCommonPolicyController@lists");
    Route::get("/tccommonpolicy/ajaxLists","TcCommonPolicyController@ajaxLists");
    Route::get("/tccommonpolicy/update","TcCommonPolicyController@update");
    Route::put("/tccommonpolicy/ajaxUpdate","TcCommonPolicyController@ajaxUpdate");
    Route::put("/tccommonpolicy/itemUpdate","TcCommonPolicyController@itemUpdate");
    Route::delete("/tccommonpolicy/ajaxDelete","TcCommonPolicyController@ajaxDelete");

    //三大平台上传政策
    Route::get("/platform/upload","PlatformController@upload");
    Route::post("/platform/ajaxUpload","PlatformController@ajaxUpload");

    //航班操作
    Route::get("/flight/add","FlightController@add");
    Route::post("/flight/ajaxAdd","FlightController@ajaxAdd");
    Route::get("/flight/lists","FlightController@lists");
    Route::get("/flight/ajaxLists","FlightController@ajaxLists");
    Route::get("/flight/update","FlightController@update");
    Route::get("/flight/ajaxUpdate","FlightController@ajaxUpdate");
    Route::get("/flight/download","FlightController@download");
    Route::get("/flight/downloadDelay","FlightController@downloadDelay");
    Route::get("/flight/downloadSevenData","FlightController@downloadSevenData");
    Route::get("/flight/downloadSevenDataDelay","FlightController@downloadSevenDataDelay");
    Route::get("/flight/downloadSevenSchedule","FlightController@downloadSevenSchedule");
    Route::get("/flight/downloadPriceSpace","FlightController@downloadPriceSpace");
    Route::get("/flight/sevenData","FlightController@sevenData");


    //天气
    Route::get("/weather/lists","WeatherController@lists");
    Route::get("/weather/ajaxLists","WeatherController@ajaxLists");
    Route::get("/weather/download",'WeatherController@download');

    //航班动态
    Route::get("/flightdynamic/add","FlightDynamicController@add");
    Route::post("/flightdynamic/ajaxAdd","FlightDynamicController@ajaxAdd");
    Route::get("/flightdynamic/lists","FlightDynamicController@lists");
    Route::get("/flightdynamic/ajaxLists","FlightDynamicController@ajaxLists");
    Route::get("/flightdynamic/update","FlightDynamicController@update");
    Route::get("/flightdynamic/ajaxUpdate","FlightDynamicController@ajaxUpdate");

    //退改管理
    Route::get('/refund/canrefund','RefundController@canRefund');
    Route::post('/refund/ajaxCanRefund','RefundController@ajaxCanRefund');

    //数据抓取数据
    Route::get('/scan/lists','ScanController@lists');
    Route::get('/scan/ajaxLists','ScanController@ajaxLists');
    Route::get('/scan/download','ScanController@download');

    //特政
    Route::get('/occupy/policylists','OccupyController@policyLists');
    Route::get('/occupy/orderlists','OccupyController@orderLists');

    //航班数据
    Route::get('/flightdata/lists','FlightDataController@lists');

    //值机
    Route::get('/flightcheck/lists','FlightCheckController@lists');
});